package com.dd.cloud.user.mapper.aicms;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.dd.cloud.user.entity.aicms.AicmsDisease;
import com.dd.cloud.user.req.aicms.DepAndFindDiseaseReq;
import com.dd.cloud.user.res.aicms.DepAndFindDiseaseRes;
import org.apache.ibatis.annotations.Param;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

/**
 * <p>
 * Mapper 接口
 * </p>
 *
 * @author czg
 * @since 2022-04-27
 */
public interface AicmsDiseaseMapper extends BaseMapper<AicmsDisease> {

    /**
     * 关键字查询疾病症状
     *
     * @param keyword
     * @param depId
     * @param nHaveChild
     * @return
     */
    List<AicmsDisease> searchKeyword(@RequestParam("keyword") String keyword, @Param("depId") String depId, @Param("nHaveChild") Integer nHaveChild);

    /**
     * 查询科室和最终疾病
     *
     * @param iPage
     * @param req
     * @return
     */
    IPage<DepAndFindDiseaseRes> queryDepAndFindDisease(IPage<?> iPage, @Param("req") DepAndFindDiseaseReq req);
}
